package com.example.springbootblog.common.exception;


import lombok.Data;

/**
 * 自定义异常
 * 1. 核心： 继承RuntimeException
 */


@Data
public  class BlogException extends RuntimeException{
    private Integer code;
    private String message;

    public BlogException(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public BlogException(String message) {
        this.message = message;
    }

    public BlogException() {
    }
}
